package com.mirror.repository;

import com.mirror.entity.oldman.Account;
import com.mirror.entity.oldman.Doctor;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

@Repository
public interface AccountRepository extends JpaRepository<Account, String>, JpaSpecificationExecutor<Account> {


    Page<Account> findAll(Pageable pageable);

    Account findAllByNumAndPassword(String num, String password);

    Account findAllByDoctor(Doctor d);

}
